<template>
  <bs-container>
    <template #list>
      <div class="svg">
         <el-card class="box-card">
          <template #header>
            <div class="title">引用element plus图标：ele + 图标名称</div>
          </template>
          <svg-icon v-for="item in elementPlusIconList" :key="item" :name="`ele-${item}`" :size="25" class="svgIcon" />
        </el-card>
        <el-card class="box-card">
          <template #header>
            <div class="title">引用自定义图标（阿里巴巴矢量图标库）：</div>
          </template>
          <svg-icon name="iconfont icon-zhongduanguanli2" :size="20" class="svgIcon" />
          <svg-icon name="iconfont icon-xiaoxi1" :size="20" class="svgIcon" />
        </el-card>
      </div>
    </template>
  </bs-container>
</template>

<script lang="ts" setup>
import * as Icons from '@element-plus/icons-vue'
import { ref,onMounted } from "vue";
const elementPlusIconList = ref<string[]>([])
onMounted(()=>{
  for (let item in Icons) {
     elementPlusIconList.value.push(item)
  }
})
</script>
<style lang="scss" scoped>
.svgIcon{
  cursor:pointer;
  margin: 10px;
}

</style>
